package com.zlcx.tz.live.vo;

import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.hibernate.annotations.DynamicInsert;
import org.hibernate.annotations.DynamicUpdate;

import java.io.Serializable;

/**
 * @author shixiaopeng
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@DynamicUpdate
@DynamicInsert
public class LearnContentVO implements Serializable {


    private static final long serialVersionUID = -5270531860677856504L;
    @ApiModelProperty(value = "id")
    private Long id;

    /**
     * 用户表tz_user的id
     */
    private Long userId;

    /**
     * 学习内容
     */
    @ApiModelProperty(value = "学习内容")
    private String content;

    /**
     * 计时分钟数
     */
    @ApiModelProperty(value = "计时分钟数")
    private Integer minutes;

    /**
     * 图标
     */
    @ApiModelProperty(value = "图标")
    private String imageUrl;
    /**
     * @see ModelEnum
     * 计时模式：1正计时，2倒计时
     */
    @ApiModelProperty(value = "计时模式：1正计时，2倒计时")
    private Integer model;

    @ApiModelProperty(value = "客户端忽略，是否删除，1已删，0未删除")
    private Integer isDelete;

    @ApiModelProperty(value = "学习状态，1未计时，2计时中，12暂停中，13继续中")
    /**
     * {@link com.sunlands.zlcx.usercenter.constant.LearningStatus}
     */
    private Integer status;

    @ApiModelProperty(value = "当日已学习次数")
    private Long curDayCount;

    @ApiModelProperty(value = "背景图url")
    private String backgroundUrl;

    @ApiModelProperty(value = "是否沉浸")
    private Boolean steep;

    @ApiModelProperty(value = "文案")
    private String copy;

    @ApiModelProperty(value = "图标id")
    private Long iconId;

    @ApiModelProperty(value = "背景图id")
    private Long backgroundId;


    public enum ModelEnum {
        invalid(1, "正计时"),
        valid(2, "倒计时");

        public final Integer code;
        public final String desc;

        ModelEnum(Integer code, String desc) {
            this.code = code;
            this.desc = desc;
        }
    }

}
